package com.hskj.dao;

import com.hskj.model.Category;
import com.hskj.model.CategoryQuery;
import com.hskj.model.Product;
import com.hskj.model.ProductQuery;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface ProductDao {

    //查询所有数据
    public List<Product> findAll();
    //条件查询
    public List<Product> select(ProductQuery query);
    // 添加操作
    public int insert(Product product);
    //修改
    public int update(Product product);
    //删除 软删除 只更改状态 不直接删除数据
    public int updateStatus(@Param("id") Integer id, @Param("status") Integer status);


}
